{% extends 'template.html' %}

{% block username %}
    {{ head.username }}
{% endblock %}

{% block content %}
    <div id="page-wrapper">
        <div class="row">
            <div class="col-lg-12">
                <h1 class="page-header">{{ head.value }}</h1>
            </div>
        </div>
        <div class="row">
            <div class="col-lg-12">
                <div class="panel panel-default">
                    <div class="panel-body">
                        <div class="form-group">
                            <!--<button id='bt-add' type="button" class="btn btn-primary xm">新增分组</button>
                            <button id='group_info' type="button" class="btn btn-primary xm">分组信息</button>
                            <button id='bt-del' type="button" class="btn btn-danger xm">删除分组</button>-->
                        </div>
                        <div class="form-group" id="show_group">
                            <select id="group" style="width: 30%">
                                <option selected="selected" value="0">选择分组</option>
                            </select>
                            <!--<button id='' type="button" class="btn btn-primary xm">查看分组信息</button>-->
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">机房</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_room_obj">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_room_obj">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_room_obj">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_room_obj">删除
                            </label>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">主机</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_host_obj">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_host_obj">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_host_obj">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_host_obj">删除
                            </label>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">业务类型</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_business_obj">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_business_obj">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_business_obj">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_business_obj">删除
                            </label>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">数据库实例</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_mysql_instance">查看
                            </label>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">游戏项目</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_game_project_obj">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_game_project_obj">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_game_project_obj">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_game_project_obj">删除
                            </label>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-2 control-label">开服计划</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="api_view_installgameserver_obj">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="api_edit_installgameserver_obj">执行
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="api_edit_installgameserver_obj">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="api_add_installgameserver_obj">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="api_delete_installgameserver_obj">删除
                            </label>
                        </div>
                        <!--<div class="form-group">
                            <label class="col-sm-2 control-label">值班表</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_duty_schedule_obj">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_duty_schedule_obj">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_duty_schedule_obj">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_duty_schedule_obj">删除
                            </label>
                        </div>-->
                        <div class="form-group">
                            <label class="col-sm-2 control-label">svn套餐权限</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_svn_scheme">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_svn_scheme">修改
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_svn_scheme">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_svn_scheme">删除
                            </label>
                        </div>

                        <div class="form-group">
                            <label class="col-sm-2 control-label">IT资产</label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="view_it_assets">查看
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="edit_it_assets">修改所有属性
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="change_assets_company">修改公司主体
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="add_it_assets">新增
                            </label>
                            <label class="checkbox-inline">
                                <input type="checkbox" id="del_it_assets">删除
                            </label>
                        </div>
                        <div class="form-group">
                            <button id='group_permission_save' type="button" class="btn btn-success xm">保存</button>
                        </div>
                    </div>
                </div>
            </div>
            <!-- Modal -->
            <div class="modal fade" id="myModal" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
                <div class="modal-dialog">
                    <div class="modal-content">
                        <div class="modal-header">
                            <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
                            <h4 class="modal-title" id="myModalLabel"></h4>
                        </div>
                        <div class="modal-body">
                            <div class="alert alert-danger alert-dismissable" id='modal-notify'>
                                <button type="button" class="close" id="bt-modal-notify">&times;</button>
                                <label id='lb-msg'></label>
                            </div>
                            <ul id="modal-list">
                                <li class="form-group">
                                    <label class="col-sm-3 control-label">分组名称</label>
                                    <div class="col-sm-7">
                                        <input type="text" class="form-control " id="group_name">
                                    </div>
                                </li>
                            </ul>
                        </div>
                        <div class="modal-footer">
                            <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                            <button id='bt-save' type="button" class="btn btn-primary">保存</button>
                        </div>
                    </div><!-- /.modal-content -->
                </div><!-- /.modal-dialog -->
            </div><!-- /.modal -->
        </div>
    </div>
{% endblock %}
{% block bodyjs %}
    <script src="/static/js/jquery.toast.min.js"></script>
    <script src="/static/js/group_permission.js"></script>
{% endblock %}
{% block css %}
    <link href="/static/css/jquery.toast.min.css" rel="stylesheet" type="text/css">
{% endblock %}
